package com.hxzy.common.core.domain.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.hxzy.common.annotation.Excel;
import lombok.Data;

import java.io.Serializable;

/**
 * 
 * @TableName xzxm_user
 */
@Data
public class XzxmUser implements Serializable {
    /**
     * 登录ID
     */
    @TableId(type = IdType.AUTO)
    private Integer userId;

    /**
     * 登录账号
     */
    private String userName;

    /**
     * 登录密码
     */
    private String userPwd;

    /**
     * 申报单位名称
     */
    private String reportingName;

    /**
     * 申报单位类型
     */
    private String reportingType;

    /**
     * 证书类型
     */
    private String certificateType;

    /**
     * 证书编号
     */
    private String certificateNumber;

    /**
     * 申报单位地址
     */
    private String reportingAddress;

    /**
     * 单位地址邮编
     */
    private String addressCode;

    /**
     * 单位联系电话
     */
    private String contactNumber;

    /**
     * 联系人姓名
     */
    private String contactName;

    /**
     * 身份证号码
     */
    private String securityNumber;

    /**
     * 电子邮箱
     */
    private String emailAddress;

    /**
     * 手机号码
     */
    private String phone;

    /**
     * 验证码
     */
    private String verificationCode;

    /**
     * 0为正常，1为停用，2为未审核
     */
    private Integer userStatus;

    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        XzxmUser other = (XzxmUser) that;
        return (this.getUserId() == null ? other.getUserId() == null : this.getUserId().equals(other.getUserId()))
            && (this.getUserName() == null ? other.getUserName() == null : this.getUserName().equals(other.getUserName()))
            && (this.getUserPwd() == null ? other.getUserPwd() == null : this.getUserPwd().equals(other.getUserPwd()))
            && (this.getReportingName() == null ? other.getReportingName() == null : this.getReportingName().equals(other.getReportingName()))
            && (this.getReportingType() == null ? other.getReportingType() == null : this.getReportingType().equals(other.getReportingType()))
            && (this.getCertificateType() == null ? other.getCertificateType() == null : this.getCertificateType().equals(other.getCertificateType()))
            && (this.getCertificateNumber() == null ? other.getCertificateNumber() == null : this.getCertificateNumber().equals(other.getCertificateNumber()))
            && (this.getReportingAddress() == null ? other.getReportingAddress() == null : this.getReportingAddress().equals(other.getReportingAddress()))
            && (this.getAddressCode() == null ? other.getAddressCode() == null : this.getAddressCode().equals(other.getAddressCode()))
            && (this.getContactNumber() == null ? other.getContactNumber() == null : this.getContactNumber().equals(other.getContactNumber()))
            && (this.getContactName() == null ? other.getContactName() == null : this.getContactName().equals(other.getContactName()))
            && (this.getSecurityNumber() == null ? other.getSecurityNumber() == null : this.getSecurityNumber().equals(other.getSecurityNumber()))
            && (this.getEmailAddress() == null ? other.getEmailAddress() == null : this.getEmailAddress().equals(other.getEmailAddress()))
            && (this.getPhone() == null ? other.getPhone() == null : this.getPhone().equals(other.getPhone()))
            && (this.getVerificationCode() == null ? other.getVerificationCode() == null : this.getVerificationCode().equals(other.getVerificationCode()))
            && (this.getUserStatus() == null ? other.getUserStatus() == null : this.getUserStatus().equals(other.getUserStatus()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getUserId() == null) ? 0 : getUserId().hashCode());
        result = prime * result + ((getUserName() == null) ? 0 : getUserName().hashCode());
        result = prime * result + ((getUserPwd() == null) ? 0 : getUserPwd().hashCode());
        result = prime * result + ((getReportingName() == null) ? 0 : getReportingName().hashCode());
        result = prime * result + ((getReportingType() == null) ? 0 : getReportingType().hashCode());
        result = prime * result + ((getCertificateType() == null) ? 0 : getCertificateType().hashCode());
        result = prime * result + ((getCertificateNumber() == null) ? 0 : getCertificateNumber().hashCode());
        result = prime * result + ((getReportingAddress() == null) ? 0 : getReportingAddress().hashCode());
        result = prime * result + ((getAddressCode() == null) ? 0 : getAddressCode().hashCode());
        result = prime * result + ((getContactNumber() == null) ? 0 : getContactNumber().hashCode());
        result = prime * result + ((getContactName() == null) ? 0 : getContactName().hashCode());
        result = prime * result + ((getSecurityNumber() == null) ? 0 : getSecurityNumber().hashCode());
        result = prime * result + ((getEmailAddress() == null) ? 0 : getEmailAddress().hashCode());
        result = prime * result + ((getPhone() == null) ? 0 : getPhone().hashCode());
        result = prime * result + ((getVerificationCode() == null) ? 0 : getVerificationCode().hashCode());
        result = prime * result + ((getUserStatus() == null) ? 0 : getUserStatus().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", userId=").append(userId);
        sb.append(", userName=").append(userName);
        sb.append(", userPwd=").append(userPwd);
        sb.append(", reportingName=").append(reportingName);
        sb.append(", reportingType=").append(reportingType);
        sb.append(", certificateType=").append(certificateType);
        sb.append(", certificateNumber=").append(certificateNumber);
        sb.append(", reportingAddress=").append(reportingAddress);
        sb.append(", addressCode=").append(addressCode);
        sb.append(", contactNumber=").append(contactNumber);
        sb.append(", contactName=").append(contactName);
        sb.append(", securityNumber=").append(securityNumber);
        sb.append(", emailAddress=").append(emailAddress);
        sb.append(", phone=").append(phone);
        sb.append(", verificationCode=").append(verificationCode);
        sb.append(", userStatus=").append(userStatus);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}